import { createApp } from "vue";
import App from "@/App.vue";
import { setupStore } from "@/store/index";
import router, { setupRouter } from "@/router/index";
// import Logger from "@/utils/Logger";

// 创建实例
const setupAll = async () => {
  const app = createApp(App);
  // store
  setupStore(app);
  // router
  setupRouter(app);
  await router.isReady();

  app.mount("#app");
};

setupAll();

// const obj: {
//   a: number;
//   b: string;
//   c: boolean;
// } = {
//   a: 1,
//   b: "hello word",
//   c: true
// };
// console.log(Object.prototype.toString.call(obj));
// Logger.printBack("对象", obj);
// console.log("=================");
// const arr: number[] = [1, 2, 3];
// console.log(Object.prototype.toString.call(arr));
// Logger.printBack("数组", arr);
// console.log("=================");
// const tuples: [number, boolean] = [1, true];
// console.log(Object.prototype.toString.call(tuples));
// Logger.printBack("元组", tuples);
// console.log("=================");
// const str: string = "hello world";
// console.log(Object.prototype.toString.call(str));
// Logger.printBack("字符串", str);
// console.log("=================");
// const num: number = 11223;
// console.log(Object.prototype.toString.call(num));
// Logger.prettySuccess("数字", num);
// console.log("=================");
// console.log(Object.prototype.toString.call(true));
// Logger.prettySuccess("boolean", true);
// console.log("=================");
// console.log(Object.prototype.toString.call(undefined));
// Logger.prettySuccess("undefined", undefined);
// console.log("=================");
// const nulls: number = null;
// console.log(Object.prototype.toString.call(nulls));
// Logger.prettySuccess("null", nulls);
// console.log("=================", typeof nulls === "object");
// const un: unknown = 123;
// console.log(Object.prototype.toString.call(un));
// Logger.prettySuccess("unknown", un);
// console.log("=================");
// const anys: any = "123";
// console.log(Object.prototype.toString.call(anys));
// Logger.prettySuccess("any", anys);
